@layout("/common/_container.html",{js:["../../../../assets/modular/system/coupon/coupon.js"]}){
<div class="layui-body-header">
    <span class="layui-body-header-title">优惠券列表</span>
</div>
assets/modular/system/discounts/coupon.js
<div class="layui-fluid" id="concat">
    <div class="layui-row layui-col-space15">
        <div class="layui-col-sm12 layui-col-md12 layui-col-lg12">
            <div class="layui-card">
                <div class="layui-card-body">
                    <div class="layui-form toolbar">
                        <div class="layui-form-item">
                            <div class="layui-inline">
                                <input id="name" class="layui-input" type="text"  placeholder="优惠券名称"/>
                            </div>
                            <div class="layui-inline">
                                <button id="btnSearch" class="layui-btn icon-btn"><i class="layui-icon" lay-filter="search">&#xe615;</i>搜索</button>
                                <button id="btnAdd" class="layui-btn icon-btn"><i class="layui-icon">&#xe654;</i>添加</button>
                                <div  style="display: inline-block;">
                                    <input type="radio" name="ratop-down" value="" title="全部" class="top" lay-filter="jiedian" checked>
                                    <input type="radio" name="ratop-down" value="1"  title="已删除" class="top" lay-filter="jiedian" >
                                    <input type="radio" name="ratop-down" value="0" title="未删除" class="top" lay-filter="jiedian" >
                                </div>
                            </div>
                        </div>
                    </div>
                    <table class="layui-table" id="couponTable" lay-filter="couponTable"></table>
                </div>
            </div>
        </div>
    </div>
</div>

<script type="text/html" id="tableBar">
    {{#  if(d.active == 0){ }}
    <a class="layui-btn layui-btn-danger layui-btn-xs" lay-event="editOrAdd">编辑</a>
    {{#  } }}



</script>
<script type="text/html" id="active">
    <div class="cell">
        <input type="checkbox"  lay-filter="active" value="{{d.id}}" lay-skin="switch" lay-text="未删除|已删除" {{d.active==0?'checked':''}} />
    </div>

</script>
@}
